package com.zyz.product.config;

import org.springframework.context.annotation.Configuration;
//import org.springframework.security.config.annotation.method.configuration.EnableGlobalMethodSecurity;
//import org.springframework.security.config.annotation.web.builders.HttpSecurity;
//import org.springframework.security.config.annotation.web.builders.WebSecurity;
//import org.springframework.security.config.annotation.web.configuration.EnableWebSecurity;
//import org.springframework.security.config.annotation.web.configuration.WebSecurityConfigurerAdapter;

/**
 * <p></p>
 *
 * @author zhang yang ze
 * @date 2019/11/3 23:09
 * @since 0.1.0
 */
//@Configuration
//@EnableWebSecurity
//@EnableGlobalMethodSecurity(prePostEnabled = true)
public class ResourceServerConfig {


//    @Override
//    public void configure(WebSecurity web) {
//        web.ignoring().antMatchers("/v2/api-docs", "/configuration/ui", "/swagger-resources/**", "/configuration/security", "/swagger-ui.html");
//    }
//
//    @Override
//    protected void configure(HttpSecurity http) throws Exception {
//        http
//                // 以/**开头的请求全部过滤
//                .antMatcher("/**")
//                .authorizeRequests()
//                // 放行公用跨域
//                .antMatchers("/", "/index", "/swagger-ui.html", "swagger-resources/**", "/v2/**")
//                .permitAll()
////                .anyRequest()
////                .authenticated()
//        ;
//    }

}
